<template>
  <basic-container>
    <invoice-management-list
      v-show="showType === 'list'"
      @openDistributionStatementDetail="openDistributionStatementDetail"
    ></invoice-management-list>
    <invoice-management-detail
      v-if="showType === 'detail'"
      @back="handleBack"
      :info="info"
    ></invoice-management-detail>
  </basic-container>
</template>

<script>
import invoiceManagementList from "@/views/financial/invoice-management-list.vue";
import invoiceManagementDetail from "@/views/financial/invoice-management-detail.vue";
export default {
  data() {
    return {
      showType: "list",
      info: {},
    };
  },
  components: {
    invoiceManagementList,
    invoiceManagementDetail,
  },
  computed: {},
  methods: {
    handleBack() {
      this.showType = "list";
    },
    openDistributionStatementDetail(info) {
      this.showType = "detail";
      this.info = info;
    },
  },
};
</script>

<!--<style scoped>-->
<!--</style>-->
